home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / programm.ing / ams__l~1.zoo / include / soundenv.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-04-25  |  985 b   |  46 lines

  1. //////////////////////////////////////////////////////////////////////////////
  2. //
  3. //  This file is part of the Atari Machine Specific Library,
  4. //  and is Copyright 1992 by Warwick W. Allison.
  5. //
  6. //  You are free to copy and modify these sources, provided you acknowledge
  7. //  the origin by retaining this notice, and adhere to the conditions
  8. //  described in the file COPYING.
  9. //
  10. //////////////////////////////////////////////////////////////////////////////
  11. #ifndef _SoundEnvelope_h
  12. #define _SoundEnvelope_h
  13.  
  14. #include <bool.h>
  15.  
  16. struct WavePoint {
  17.     short Pitch;
  18.     short Volume;
  19. };
  20.  
  21. class SoundEnvelope {
  22. public:
  23.     SoundEnvelope(
  24.             short StartPitch, short PitchChange,
  25.             short StartVolume, short VolumeChange,
  26.             short StartPriority, short PriorityChange,
  27.             bool Noisy
  28.         );
  29.  
  30.     SoundEnvelope(WavePoint* WaveForm,
  31.             short StartPriority, short PriorityChange,
  32.             bool Noisy
  33.         );
  34.  
  35.     void Start();
  36.  
  37. private:
  38.     short P,dP,V,dV,Pr,dPr;
  39.     bool N,Wave;
  40.     WavePoint* D;
  41. };
  42.  
  43. short DoSounds();
  44.  
  45. #endif
  46.